package com.ekuaitu.kuaitustaff.utils.ble.utils;

/**
 *
 */

import java.util.concurrent.atomic.AtomicInteger;

/**
 * @author Administrator
 */
public final class AtomicIntegerUtil {

    private static final AtomicInteger mAtomicInteger = new AtomicInteger(0);

    public synchronized static byte[] getIncrementBytesID() {
        short serialNumber = (short) (mAtomicInteger.getAndIncrement() % 65536);
        return ConvertUtil.shortToBytes(serialNumber, true);
    }
}
